﻿using System;
using System.Net;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Documents;
using System.Windows.Ink;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Shapes;

namespace Galaktika.BI.Runtime.Services
{
    [System.Diagnostics.DebuggerStepThroughAttribute()]
    [System.CodeDom.Compiler.GeneratedCodeAttribute("System.Runtime.Serialization", "3.0.0.0")]
    [System.Runtime.Serialization.CollectionDataContractAttribute(Name = "ArrayOfScoresResult", Namespace = "http://tempuri.org/", ItemName = "ScoresResult")]
    public class ArrayOfScoresResult : System.Collections.ObjectModel.ObservableCollection<ScoresResult>
    {
    }

    [System.Diagnostics.DebuggerStepThroughAttribute()]
    [System.CodeDom.Compiler.GeneratedCodeAttribute("System.Runtime.Serialization", "3.0.0.0")]
    [System.Runtime.Serialization.DataContractAttribute(Name = "ScoresResult", Namespace = "http://www.galaktika.by/bi/3.0/")]
    public partial class ScoresResult : object, System.ComponentModel.INotifyPropertyChanged
    {

        private string WidthField;

        private string HeightField;

        private string ColorsField;

        private string ScoreField;

        private string DateField;

        private string TimeField;

        private string CodeField;

        private string NameField;

        [System.Runtime.Serialization.DataMemberAttribute(IsRequired = true)]
        public string Width
        {
            get
            {
                return this.WidthField;
            }
            set
            {
                if ((object.ReferenceEquals(this.WidthField, value) != true))
                {
                    this.WidthField = value;
                    this.RaisePropertyChanged("Width");
                }
            }
        }

        [System.Runtime.Serialization.DataMemberAttribute(IsRequired = true, Order = 1)]
        public string Height
        {
            get
            {
                return this.HeightField;
            }
            set
            {
                if ((object.ReferenceEquals(this.HeightField, value) != true))
                {
                    this.HeightField = value;
                    this.RaisePropertyChanged("Height");
                }
            }
        }

        [System.Runtime.Serialization.DataMemberAttribute(IsRequired = true, Order = 2)]
        public string Colors
        {
            get
            {
                return this.ColorsField;
            }
            set
            {
                if ((object.ReferenceEquals(this.ColorsField, value) != true))
                {
                    this.ColorsField = value;
                    this.RaisePropertyChanged("Colors");
                }
            }
        }

        [System.Runtime.Serialization.DataMemberAttribute(EmitDefaultValue = false, Order = 3)]
        public string Score
        {
            get
            {
                return this.ScoreField;
            }
            set
            {
                if ((object.ReferenceEquals(this.ScoreField, value) != true))
                {
                    this.ScoreField = value;
                    this.RaisePropertyChanged("Score");
                }
            }
        }

        [System.Runtime.Serialization.DataMemberAttribute(IsRequired = true, Order = 4)]
        public string Date
        {
            get
            {
                return this.DateField;
            }
            set
            {
                if ((object.ReferenceEquals(this.DateField, value) != true))
                {
                    this.DateField = value;
                    this.RaisePropertyChanged("Date");
                }
            }
        }

        [System.Runtime.Serialization.DataMemberAttribute(IsRequired = true, Order = 5)]
        public string Time
        {
            get
            {
                return this.TimeField;
            }
            set
            {
                if ((object.ReferenceEquals(this.TimeField, value) != true))
                {
                    this.TimeField = value;
                    this.RaisePropertyChanged("Time");
                }
            }
        }

        [System.Runtime.Serialization.DataMemberAttribute(EmitDefaultValue = false, Order = 6)]
        public string Code
        {
            get
            {
                return this.CodeField;
            }
            set
            {
                if ((object.ReferenceEquals(this.CodeField, value) != true))
                {
                    this.CodeField = value;
                    this.RaisePropertyChanged("Code");
                }
            }
        }

        [System.Runtime.Serialization.DataMemberAttribute(EmitDefaultValue = false, Order = 7)]
        public string Name
        {
            get
            {
                return this.NameField;
            }
            set
            {
                if ((object.ReferenceEquals(this.NameField, value) != true))
                {
                    this.NameField = value;
                    this.RaisePropertyChanged("Name");
                }
            }
        }

        public event System.ComponentModel.PropertyChangedEventHandler PropertyChanged;

        protected void RaisePropertyChanged(string propertyName)
        {
            System.ComponentModel.PropertyChangedEventHandler propertyChanged = this.PropertyChanged;
            if ((propertyChanged != null))
            {
                propertyChanged(this, new System.ComponentModel.PropertyChangedEventArgs(propertyName));
            }
        }
    }

    [System.CodeDom.Compiler.GeneratedCodeAttribute("System.ServiceModel", "3.0.0.0")]
    [System.ServiceModel.ServiceContractAttribute(ConfigurationName = "ScoresRef.ScoresSoap")]
    public interface ScoresSoap
    {

        [System.ServiceModel.OperationContractAttribute(AsyncPattern = true, Action = "http://tempuri.org/InvokeCommand", ReplyAction = "*")]
        System.IAsyncResult BeginInvokeCommand( InvokeCommandRequest request, System.AsyncCallback callback, object asyncState);

         InvokeCommandResponse EndInvokeCommand(System.IAsyncResult result);

        [System.ServiceModel.OperationContractAttribute(AsyncPattern = true, Action = "http://tempuri.org/GetTop5", ReplyAction = "*")]
        System.IAsyncResult BeginGetTop5( GetTop5Request request, System.AsyncCallback callback, object asyncState);

         GetTop5Response EndGetTop5(System.IAsyncResult result);

        [System.ServiceModel.OperationContractAttribute(AsyncPattern = true, Action = "http://tempuri.org/AddScore", ReplyAction = "*")]
        System.IAsyncResult BeginAddScore( AddScoreRequest request, System.AsyncCallback callback, object asyncState);

         AddScoreResponse EndAddScore(System.IAsyncResult result);
    }

    [System.Diagnostics.DebuggerStepThroughAttribute()]
    [System.CodeDom.Compiler.GeneratedCodeAttribute("System.ServiceModel", "3.0.0.0")]
    [System.ServiceModel.MessageContractAttribute(WrapperName = "InvokeCommand", WrapperNamespace = "http://tempuri.org/", IsWrapped = true)]
    public partial class InvokeCommandRequest
    {

        [System.ServiceModel.MessageBodyMemberAttribute(Namespace = "http://www.galaktika.by/bi/3.0/", Order = 0)]
        public Galaktika.BI.Runtime.Services.InvokeSchema invoker;

        public InvokeCommandRequest()
        {
        }

        public InvokeCommandRequest(Galaktika.BI.Runtime.Services.InvokeSchema invoker)
        {
            this.invoker = invoker;
        }
    }

    [System.Diagnostics.DebuggerStepThroughAttribute()]
    [System.CodeDom.Compiler.GeneratedCodeAttribute("System.ServiceModel", "3.0.0.0")]
    [System.ServiceModel.MessageContractAttribute(WrapperName = "InvokeCommandResponse", WrapperNamespace = "http://tempuri.org/", IsWrapped = true)]
    public partial class InvokeCommandResponse
    {

        [System.ServiceModel.MessageBodyMemberAttribute(Namespace = "http://www.galaktika.by/bi/3.0/", Order = 0)]
        public Galaktika.BI.Runtime.Services.InvokeResultSchema InvokeCommandResult;

        public InvokeCommandResponse()
        {
        }

        public InvokeCommandResponse(Galaktika.BI.Runtime.Services.InvokeResultSchema InvokeCommandResult)
        {
            this.InvokeCommandResult = InvokeCommandResult;
        }
    }

    [System.Diagnostics.DebuggerStepThroughAttribute()]
    [System.CodeDom.Compiler.GeneratedCodeAttribute("System.ServiceModel", "3.0.0.0")]
    [System.ServiceModel.MessageContractAttribute(IsWrapped = false)]
    public partial class GetTop5Request
    {

        [System.ServiceModel.MessageBodyMemberAttribute(Name = "GetTop5", Namespace = "http://tempuri.org/", Order = 0)]
        public  GetTop5RequestBody Body;

        public GetTop5Request()
        {
        }

        public GetTop5Request( GetTop5RequestBody Body)
        {
            this.Body = Body;
        }
    }

    [System.Diagnostics.DebuggerStepThroughAttribute()]
    [System.CodeDom.Compiler.GeneratedCodeAttribute("System.ServiceModel", "3.0.0.0")]
    [System.Runtime.Serialization.DataContractAttribute()]
    public partial class GetTop5RequestBody
    {

        public GetTop5RequestBody()
        {
        }
    }

    [System.Diagnostics.DebuggerStepThroughAttribute()]
    [System.CodeDom.Compiler.GeneratedCodeAttribute("System.ServiceModel", "3.0.0.0")]
    [System.ServiceModel.MessageContractAttribute(IsWrapped = false)]
    public partial class GetTop5Response
    {

        [System.ServiceModel.MessageBodyMemberAttribute(Name = "GetTop5Response", Namespace = "http://tempuri.org/", Order = 0)]
        public  GetTop5ResponseBody Body;

        public GetTop5Response()
        {
        }

        public GetTop5Response( GetTop5ResponseBody Body)
        {
            this.Body = Body;
        }
    }

    [System.Diagnostics.DebuggerStepThroughAttribute()]
    [System.CodeDom.Compiler.GeneratedCodeAttribute("System.ServiceModel", "3.0.0.0")]
    [System.Runtime.Serialization.DataContractAttribute(Namespace = "http://tempuri.org/")]
    public partial class GetTop5ResponseBody
    {

        [System.Runtime.Serialization.DataMemberAttribute(EmitDefaultValue = false, Order = 0)]
        public  ArrayOfScoresResult GetTop5Result;

        public GetTop5ResponseBody()
        {
        }

        public GetTop5ResponseBody( ArrayOfScoresResult GetTop5Result)
        {
            this.GetTop5Result = GetTop5Result;
        }
    }

    [System.Diagnostics.DebuggerStepThroughAttribute()]
    [System.CodeDom.Compiler.GeneratedCodeAttribute("System.ServiceModel", "3.0.0.0")]
    [System.ServiceModel.MessageContractAttribute(IsWrapped = false)]
    public partial class AddScoreRequest
    {

        [System.ServiceModel.MessageBodyMemberAttribute(Name = "AddScore", Namespace = "http://tempuri.org/", Order = 0)]
        public  AddScoreRequestBody Body;

        public AddScoreRequest()
        {
        }

        public AddScoreRequest( AddScoreRequestBody Body)
        {
            this.Body = Body;
        }
    }

    [System.Diagnostics.DebuggerStepThroughAttribute()]
    [System.CodeDom.Compiler.GeneratedCodeAttribute("System.ServiceModel", "3.0.0.0")]
    [System.Runtime.Serialization.DataContractAttribute(Namespace = "http://tempuri.org/")]
    public partial class AddScoreRequestBody
    {

        [System.Runtime.Serialization.DataMemberAttribute(EmitDefaultValue = false, Order = 0)]
        public string width;

        [System.Runtime.Serialization.DataMemberAttribute(EmitDefaultValue = false, Order = 1)]
        public string height;

        [System.Runtime.Serialization.DataMemberAttribute(EmitDefaultValue = false, Order = 2)]
        public string colors;

        [System.Runtime.Serialization.DataMemberAttribute(EmitDefaultValue = false, Order = 3)]
        public string score;

        [System.Runtime.Serialization.DataMemberAttribute(EmitDefaultValue = false, Order = 4)]
        public string date;

        [System.Runtime.Serialization.DataMemberAttribute(EmitDefaultValue = false, Order = 5)]
        public string time;

        [System.Runtime.Serialization.DataMemberAttribute(EmitDefaultValue = false, Order = 6)]
        public string code;

        [System.Runtime.Serialization.DataMemberAttribute(EmitDefaultValue = false, Order = 7)]
        public string name;

        public AddScoreRequestBody()
        {
        }

        public AddScoreRequestBody(string width, string height, string colors, string score, string date, string time, string code, string name)
        {
            this.width = width;
            this.height = height;
            this.colors = colors;
            this.score = score;
            this.date = date;
            this.time = time;
            this.code = code;
            this.name = name;
        }
    }

    [System.Diagnostics.DebuggerStepThroughAttribute()]
    [System.CodeDom.Compiler.GeneratedCodeAttribute("System.ServiceModel", "3.0.0.0")]
    [System.ServiceModel.MessageContractAttribute(IsWrapped = false)]
    public partial class AddScoreResponse
    {

        [System.ServiceModel.MessageBodyMemberAttribute(Name = "AddScoreResponse", Namespace = "http://tempuri.org/", Order = 0)]
        public  AddScoreResponseBody Body;

        public AddScoreResponse()
        {
        }

        public AddScoreResponse( AddScoreResponseBody Body)
        {
            this.Body = Body;
        }
    }

    [System.Diagnostics.DebuggerStepThroughAttribute()]
    [System.CodeDom.Compiler.GeneratedCodeAttribute("System.ServiceModel", "3.0.0.0")]
    [System.Runtime.Serialization.DataContractAttribute()]
    public partial class AddScoreResponseBody
    {

        public AddScoreResponseBody()
        {
        }
    }

    [System.CodeDom.Compiler.GeneratedCodeAttribute("System.ServiceModel", "3.0.0.0")]
    public interface ScoresSoapChannel :  ScoresSoap, System.ServiceModel.IClientChannel
    {
    }    

    [System.Diagnostics.DebuggerStepThroughAttribute()]
    [System.CodeDom.Compiler.GeneratedCodeAttribute("System.ServiceModel", "3.0.0.0")]
    public partial class GetTop5CompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs
    {

        private object[] results;

        public GetTop5CompletedEventArgs(object[] results, System.Exception exception, bool cancelled, object userState) :
            base(exception, cancelled, userState)
        {
            this.results = results;
        }

        public  ArrayOfScoresResult Result
        {
            get
            {
                base.RaiseExceptionIfNecessary();
                return (( ArrayOfScoresResult)(this.results[0]));
            }
        }
    }

    [System.CodeDom.Compiler.GeneratedCodeAttribute("System.ServiceModel", "3.0.0.0")]
    public partial class ScoresSoapClient : System.ServiceModel.ClientBase< ScoresSoap>,  ScoresSoap
    {

        private BeginOperationDelegate onBeginInvokeCommandDelegate;

        private EndOperationDelegate onEndInvokeCommandDelegate;

        private System.Threading.SendOrPostCallback onInvokeCommandCompletedDelegate;

        private BeginOperationDelegate onBeginGetTop5Delegate;

        private EndOperationDelegate onEndGetTop5Delegate;

        private System.Threading.SendOrPostCallback onGetTop5CompletedDelegate;

        private BeginOperationDelegate onBeginAddScoreDelegate;

        private EndOperationDelegate onEndAddScoreDelegate;

        private System.Threading.SendOrPostCallback onAddScoreCompletedDelegate;

        private BeginOperationDelegate onBeginOpenDelegate;

        private EndOperationDelegate onEndOpenDelegate;

        private System.Threading.SendOrPostCallback onOpenCompletedDelegate;

        private BeginOperationDelegate onBeginCloseDelegate;

        private EndOperationDelegate onEndCloseDelegate;

        private System.Threading.SendOrPostCallback onCloseCompletedDelegate;

        public ScoresSoapClient()
        {
        }

        public ScoresSoapClient(string endpointConfigurationName) :
            base(endpointConfigurationName)
        {
        }

        public ScoresSoapClient(string endpointConfigurationName, string remoteAddress) :
            base(endpointConfigurationName, remoteAddress)
        {
        }

        public ScoresSoapClient(string endpointConfigurationName, System.ServiceModel.EndpointAddress remoteAddress) :
            base(endpointConfigurationName, remoteAddress)
        {
        }

        public ScoresSoapClient(System.ServiceModel.Channels.Binding binding, System.ServiceModel.EndpointAddress remoteAddress) :
            base(binding, remoteAddress)
        {
        }

        public event System.EventHandler<InvokeCommandCompletedEventArgs> InvokeCommandCompleted;

        public event System.EventHandler<GetTop5CompletedEventArgs> GetTop5Completed;

        public event System.EventHandler<System.ComponentModel.AsyncCompletedEventArgs> AddScoreCompleted;

        public event System.EventHandler<System.ComponentModel.AsyncCompletedEventArgs> OpenCompleted;

        public event System.EventHandler<System.ComponentModel.AsyncCompletedEventArgs> CloseCompleted;

        [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)]
        System.IAsyncResult  ScoresSoap.BeginInvokeCommand( InvokeCommandRequest request, System.AsyncCallback callback, object asyncState)
        {
            return base.Channel.BeginInvokeCommand(request, callback, asyncState);
        }

        [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)]
        private System.IAsyncResult BeginInvokeCommand(Galaktika.BI.Runtime.Services.InvokeSchema invoker, System.AsyncCallback callback, object asyncState)
        {
             InvokeCommandRequest inValue = new  InvokeCommandRequest();
            inValue.invoker = invoker;
            return (( ScoresSoap)(this)).BeginInvokeCommand(inValue, callback, asyncState);
        }

        [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)]
         InvokeCommandResponse  ScoresSoap.EndInvokeCommand(System.IAsyncResult result)
        {
            return base.Channel.EndInvokeCommand(result);
        }

        [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)]
        private Galaktika.BI.Runtime.Services.InvokeResultSchema EndInvokeCommand(System.IAsyncResult result)
        {
             InvokeCommandResponse retVal = (( ScoresSoap)(this)).EndInvokeCommand(result);
            return retVal.InvokeCommandResult;
        }

        private System.IAsyncResult OnBeginInvokeCommand(object[] inValues, System.AsyncCallback callback, object asyncState)
        {
            Galaktika.BI.Runtime.Services.InvokeSchema invoker = ((Galaktika.BI.Runtime.Services.InvokeSchema)(inValues[0]));
            return this.BeginInvokeCommand(invoker, callback, asyncState);
        }

        private object[] OnEndInvokeCommand(System.IAsyncResult result)
        {
            Galaktika.BI.Runtime.Services.InvokeResultSchema retVal = this.EndInvokeCommand(result);
            return new object[] {
                    retVal};
        }

        private void OnInvokeCommandCompleted(object state)
        {
            if ((this.InvokeCommandCompleted != null))
            {
                InvokeAsyncCompletedEventArgs e = ((InvokeAsyncCompletedEventArgs)(state));
                this.InvokeCommandCompleted(this, new InvokeCommandCompletedEventArgs(e.Results, e.Error, e.Cancelled, e.UserState));
            }
        }

        public void InvokeCommandAsync(Galaktika.BI.Runtime.Services.InvokeSchema invoker)
        {
            this.InvokeCommandAsync(invoker, null);
        }

        public void InvokeCommandAsync(Galaktika.BI.Runtime.Services.InvokeSchema invoker, object userState)
        {
            if ((this.onBeginInvokeCommandDelegate == null))
            {
                this.onBeginInvokeCommandDelegate = new BeginOperationDelegate(this.OnBeginInvokeCommand);
            }
            if ((this.onEndInvokeCommandDelegate == null))
            {
                this.onEndInvokeCommandDelegate = new EndOperationDelegate(this.OnEndInvokeCommand);
            }
            if ((this.onInvokeCommandCompletedDelegate == null))
            {
                this.onInvokeCommandCompletedDelegate = new System.Threading.SendOrPostCallback(this.OnInvokeCommandCompleted);
            }
            base.InvokeAsync(this.onBeginInvokeCommandDelegate, new object[] {
                        invoker}, this.onEndInvokeCommandDelegate, this.onInvokeCommandCompletedDelegate, userState);
        }

        [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)]
        System.IAsyncResult  ScoresSoap.BeginGetTop5( GetTop5Request request, System.AsyncCallback callback, object asyncState)
        {
            return base.Channel.BeginGetTop5(request, callback, asyncState);
        }

        [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)]
        private System.IAsyncResult BeginGetTop5(System.AsyncCallback callback, object asyncState)
        {
             GetTop5Request inValue = new  GetTop5Request();
            inValue.Body = new  GetTop5RequestBody();
            return (( ScoresSoap)(this)).BeginGetTop5(inValue, callback, asyncState);
        }

        [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)]
         GetTop5Response  ScoresSoap.EndGetTop5(System.IAsyncResult result)
        {
            return base.Channel.EndGetTop5(result);
        }

        [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)]
        private  ArrayOfScoresResult EndGetTop5(System.IAsyncResult result)
        {
             GetTop5Response retVal = (( ScoresSoap)(this)).EndGetTop5(result);
            return retVal.Body.GetTop5Result;
        }

        private System.IAsyncResult OnBeginGetTop5(object[] inValues, System.AsyncCallback callback, object asyncState)
        {
            return this.BeginGetTop5(callback, asyncState);
        }

        private object[] OnEndGetTop5(System.IAsyncResult result)
        {
             ArrayOfScoresResult retVal = this.EndGetTop5(result);
            return new object[] {
                    retVal};
        }

        private void OnGetTop5Completed(object state)
        {
            if ((this.GetTop5Completed != null))
            {
                InvokeAsyncCompletedEventArgs e = ((InvokeAsyncCompletedEventArgs)(state));
                this.GetTop5Completed(this, new GetTop5CompletedEventArgs(e.Results, e.Error, e.Cancelled, e.UserState));
            }
        }

        public void GetTop5Async()
        {
            this.GetTop5Async(null);
        }

        public void GetTop5Async(object userState)
        {
            if ((this.onBeginGetTop5Delegate == null))
            {
                this.onBeginGetTop5Delegate = new BeginOperationDelegate(this.OnBeginGetTop5);
            }
            if ((this.onEndGetTop5Delegate == null))
            {
                this.onEndGetTop5Delegate = new EndOperationDelegate(this.OnEndGetTop5);
            }
            if ((this.onGetTop5CompletedDelegate == null))
            {
                this.onGetTop5CompletedDelegate = new System.Threading.SendOrPostCallback(this.OnGetTop5Completed);
            }
            base.InvokeAsync(this.onBeginGetTop5Delegate, null, this.onEndGetTop5Delegate, this.onGetTop5CompletedDelegate, userState);
        }

        [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)]
        System.IAsyncResult  ScoresSoap.BeginAddScore( AddScoreRequest request, System.AsyncCallback callback, object asyncState)
        {
            return base.Channel.BeginAddScore(request, callback, asyncState);
        }

        [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)]
        private System.IAsyncResult BeginAddScore(string width, string height, string colors, string score, string date, string time, string code, string name, System.AsyncCallback callback, object asyncState)
        {
             AddScoreRequest inValue = new  AddScoreRequest();
            inValue.Body = new  AddScoreRequestBody();
            inValue.Body.width = width;
            inValue.Body.height = height;
            inValue.Body.colors = colors;
            inValue.Body.score = score;
            inValue.Body.date = date;
            inValue.Body.time = time;
            inValue.Body.code = code;
            inValue.Body.name = name;
            return (( ScoresSoap)(this)).BeginAddScore(inValue, callback, asyncState);
        }

        [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)]
         AddScoreResponse  ScoresSoap.EndAddScore(System.IAsyncResult result)
        {
            return base.Channel.EndAddScore(result);
        }

        [System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)]
        private void EndAddScore(System.IAsyncResult result)
        {
             AddScoreResponse retVal = (( ScoresSoap)(this)).EndAddScore(result);
        }

        private System.IAsyncResult OnBeginAddScore(object[] inValues, System.AsyncCallback callback, object asyncState)
        {
            string width = ((string)(inValues[0]));
            string height = ((string)(inValues[1]));
            string colors = ((string)(inValues[2]));
            string score = ((string)(inValues[3]));
            string date = ((string)(inValues[4]));
            string time = ((string)(inValues[5]));
            string code = ((string)(inValues[6]));
            string name = ((string)(inValues[7]));
            return this.BeginAddScore(width, height, colors, score, date, time, code, name, callback, asyncState);
        }

        private object[] OnEndAddScore(System.IAsyncResult result)
        {
            this.EndAddScore(result);
            return null;
        }

        private void OnAddScoreCompleted(object state)
        {
            if ((this.AddScoreCompleted != null))
            {
                InvokeAsyncCompletedEventArgs e = ((InvokeAsyncCompletedEventArgs)(state));
                this.AddScoreCompleted(this, new System.ComponentModel.AsyncCompletedEventArgs(e.Error, e.Cancelled, e.UserState));
            }
        }

        public void AddScoreAsync(string width, string height, string colors, string score, string date, string time, string code, string name)
        {
            this.AddScoreAsync(width, height, colors, score, date, time, code, name, null);
        }

        public void AddScoreAsync(string width, string height, string colors, string score, string date, string time, string code, string name, object userState)
        {
            if ((this.onBeginAddScoreDelegate == null))
            {
                this.onBeginAddScoreDelegate = new BeginOperationDelegate(this.OnBeginAddScore);
            }
            if ((this.onEndAddScoreDelegate == null))
            {
                this.onEndAddScoreDelegate = new EndOperationDelegate(this.OnEndAddScore);
            }
            if ((this.onAddScoreCompletedDelegate == null))
            {
                this.onAddScoreCompletedDelegate = new System.Threading.SendOrPostCallback(this.OnAddScoreCompleted);
            }
            base.InvokeAsync(this.onBeginAddScoreDelegate, new object[] {
                        width,
                        height,
                        colors,
                        score,
                        date,
                        time,
                        code,
                        name}, this.onEndAddScoreDelegate, this.onAddScoreCompletedDelegate, userState);
        }

        private System.IAsyncResult OnBeginOpen(object[] inValues, System.AsyncCallback callback, object asyncState)
        {
            return ((System.ServiceModel.ICommunicationObject)(this)).BeginOpen(callback, asyncState);
        }

        private object[] OnEndOpen(System.IAsyncResult result)
        {
            ((System.ServiceModel.ICommunicationObject)(this)).EndOpen(result);
            return null;
        }

        private void OnOpenCompleted(object state)
        {
            if ((this.OpenCompleted != null))
            {
                InvokeAsyncCompletedEventArgs e = ((InvokeAsyncCompletedEventArgs)(state));
                this.OpenCompleted(this, new System.ComponentModel.AsyncCompletedEventArgs(e.Error, e.Cancelled, e.UserState));
            }
        }

        public void OpenAsync()
        {
            this.OpenAsync(null);
        }

        public void OpenAsync(object userState)
        {
            if ((this.onBeginOpenDelegate == null))
            {
                this.onBeginOpenDelegate = new BeginOperationDelegate(this.OnBeginOpen);
            }
            if ((this.onEndOpenDelegate == null))
            {
                this.onEndOpenDelegate = new EndOperationDelegate(this.OnEndOpen);
            }
            if ((this.onOpenCompletedDelegate == null))
            {
                this.onOpenCompletedDelegate = new System.Threading.SendOrPostCallback(this.OnOpenCompleted);
            }
            base.InvokeAsync(this.onBeginOpenDelegate, null, this.onEndOpenDelegate, this.onOpenCompletedDelegate, userState);
        }

        private System.IAsyncResult OnBeginClose(object[] inValues, System.AsyncCallback callback, object asyncState)
        {
            return ((System.ServiceModel.ICommunicationObject)(this)).BeginClose(callback, asyncState);
        }

        private object[] OnEndClose(System.IAsyncResult result)
        {
            ((System.ServiceModel.ICommunicationObject)(this)).EndClose(result);
            return null;
        }

        private void OnCloseCompleted(object state)
        {
            if ((this.CloseCompleted != null))
            {
                InvokeAsyncCompletedEventArgs e = ((InvokeAsyncCompletedEventArgs)(state));
                this.CloseCompleted(this, new System.ComponentModel.AsyncCompletedEventArgs(e.Error, e.Cancelled, e.UserState));
            }
        }

        public void CloseAsync()
        {
            this.CloseAsync(null);
        }

        public void CloseAsync(object userState)
        {
            if ((this.onBeginCloseDelegate == null))
            {
                this.onBeginCloseDelegate = new BeginOperationDelegate(this.OnBeginClose);
            }
            if ((this.onEndCloseDelegate == null))
            {
                this.onEndCloseDelegate = new EndOperationDelegate(this.OnEndClose);
            }
            if ((this.onCloseCompletedDelegate == null))
            {
                this.onCloseCompletedDelegate = new System.Threading.SendOrPostCallback(this.OnCloseCompleted);
            }
            base.InvokeAsync(this.onBeginCloseDelegate, null, this.onEndCloseDelegate, this.onCloseCompletedDelegate, userState);
        }

        protected override  ScoresSoap CreateChannel()
        {
            return new ScoresSoapClientChannel(this);
        }

        private class ScoresSoapClientChannel : ChannelBase< ScoresSoap>,  ScoresSoap
        {

            public ScoresSoapClientChannel(System.ServiceModel.ClientBase< ScoresSoap> client) :
                base(client)
            {
            }

            public System.IAsyncResult BeginInvokeCommand( InvokeCommandRequest request, System.AsyncCallback callback, object asyncState)
            {
                object[] _args = new object[1];
                _args[0] = request;
                System.IAsyncResult _result = base.BeginInvoke("InvokeCommand", _args, callback, asyncState);
                return _result;
            }

            public  InvokeCommandResponse EndInvokeCommand(System.IAsyncResult result)
            {
                object[] _args = new object[0];
                 InvokeCommandResponse _result = (( InvokeCommandResponse)(base.EndInvoke("InvokeCommand", _args, result)));
                return _result;
            }

            public System.IAsyncResult BeginGetTop5( GetTop5Request request, System.AsyncCallback callback, object asyncState)
            {
                object[] _args = new object[1];
                _args[0] = request;
                System.IAsyncResult _result = base.BeginInvoke("GetTop5", _args, callback, asyncState);
                return _result;
            }

            public  GetTop5Response EndGetTop5(System.IAsyncResult result)
            {
                object[] _args = new object[0];
                 GetTop5Response _result = (( GetTop5Response)(base.EndInvoke("GetTop5", _args, result)));
                return _result;
            }

            public System.IAsyncResult BeginAddScore( AddScoreRequest request, System.AsyncCallback callback, object asyncState)
            {
                object[] _args = new object[1];
                _args[0] = request;
                System.IAsyncResult _result = base.BeginInvoke("AddScore", _args, callback, asyncState);
                return _result;
            }

            public  AddScoreResponse EndAddScore(System.IAsyncResult result)
            {
                object[] _args = new object[0];
                 AddScoreResponse _result = (( AddScoreResponse)(base.EndInvoke("AddScore", _args, result)));
                return _result;
            }
        }
    }
}
